<%--
  Created by IntelliJ IDEA.
  User: 86185
  Date: 2024/6/21
  Time: 14:48
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0, user-scalable=no">
    <title>vue购物车地址订单详情代码 - 站长素材</title>

    <!--css类引用-->
    <link rel="stylesheet" href="user/plugins/bootstrap/bootstrap.min.css"/>
    <link rel="stylesheet" href="user/plugins/layui/css/layui.css"/>
    <link rel="stylesheet" href="user/plugins/awesome/css/font-awesome.min.css"/>
    <link rel="stylesheet" href="user/plugins/eleme-ui/index.css"/>
    <link rel="stylesheet" href="css/CivilMilitaryIntegration/public.css"/>
    <link rel="stylesheet" href="user/css/CivilMilitaryIntegration/ShoppingCartAdress.css"/>

</head>
<body>
<!--toper 公用-->

<!--主要内容-->
<div class="row" id="myVue" v-cloak>
    <div class="col-lg-10 col-lg-offset-1"><br>
        <div class="contenter">
            <ul>
                <li>
                    <span class="addAddressCons">订单列表</span>
                    <div class="row deliverymode">
                        <div class="col-lg-12 deliverymodeRight">
                            <div class="layui-form">
                                <table class="layui-table">
                                    <c:forEach items="${orders}" var="order" varStatus="status">
                                        <tr>
                                            <td>
                                                <span class="goodName">
                                                    <img class="goodImg" src="${order.goodsImageUrl}"/>
                                                </span>
                                                <span class="goodName goodsName">
                                                    <h2 class="goodname"></h2>
                                                    <p class="goodGary">
                                                        <span>商品名：</span>
                                                        <span>${order.goodsName}</span>
                                                    </p>
                                                    <p class="goodGary">
                                                        <span>购买数量：</span>
                                                        <span>${order.goodsNum}</span>
                                                    </p>
                                                </span>
                                            </td>
                                            <td class="goodPrice">单价：$ ${order.goodsPrice}</td>
                                            <td class="goodPrice">共：$ ${order.goodsPrice * order.goodsNum}</td>
                                            <td class="goodGary">收货人：${order.conName}</td>
                                            <td class="goodGary">收货地址：${order.address}</td>
                                            <td class="goodGary" style="color: red">订单状态：
                                                <c:if test="${order.orderState == 1}">
                                                    未支付
                                                </c:if>
                                                <c:if test="${order.orderState == 2}">
                                                    待发货
                                                </c:if>
                                                <c:if test="${order.orderState == 3}">
                                                    待收货
                                                </c:if>
                                                <c:if test="${order.orderState == 4}">
                                                    确定收货
                                                </c:if>
                                                <c:if test="${order.orderState == 5}">
                                                    已取消
                                                </c:if>
                                            </td>
                                            <td>
                                                <c:if test="${order.orderState == 1}">
                                                    <a class="btn submitForm" href="UpdateUserOrderStateServlet?id=${order.id}&orderState=5" style="background-color: green">取消订单</a>
                                                    <a class="btn submitForm" href="UpdateUserOrderStateServlet?id=${order.id}&orderState=2" style="background-color: #6f42c1">付款</a>
                                                </c:if>
                                                <c:if test="${order.orderState == 2}">
                                                    <a class="btn submitForm"  style="background-color: green" href="UpdateUserOrderStateServlet?id=${order.id}&orderState=5">取消订单</a>
                                                </c:if>
                                                <c:if test="${order.orderState == 3}">
                                                    <a class="btn submitForm" href="UpdateUserOrderStateServlet?id=${order.id}&orderState=4">收货</a>
                                                </c:if>
                                                <c:if test="${order.orderState == 4}">
                                                    <a class="btn submitForm" style="background-color: red" href="DeleteOrderServlet?id=${order.id}">删除</a>
                                                </c:if>
                                                <c:if test="${order.orderState == 5}">

                                                </c:if>
                                            </td>
                                        </tr>
                                    </c:forEach>
                                </table>
                            </div>
                        </div>
                    </div>
                </li>
            </ul>
        </div>
    </div>


</div>

<!--js类引用-->
<script type="text/javascript" src="user/plugins/jquery/jquery.min.js"></script>
<script type="text/javascript" src="user/plugins/bootstrap/bootstrap.min.js"></script>
<script type="text/javascript" src="user/plugins/vue/vue.js"></script>
<script type="text/javascript" src="user/plugins/eleme-ui/index.js"></script>
<script type="text/javascript" src="user/js/CivilMilitaryIntegration/ShoppingCart.js"></script>
<!--<script type="text/javascript" src="js/CivilMilitaryIntegration/abc.js" ></script>-->

<div style="text-align:center;margin:50px 0; font:normal 14px/24px 'MicroSoft YaHei';">
    <p>适用浏览器：360、FireFox、Chrome、Opera、傲游、搜狗、世界之窗. 不支持Safari、IE8及以下浏览器。</p>
    <p>来源：<a href="http://sc.chinaz.com/" target="_blank">站长素材</a></p>
</div>
</body>
</html>
